//
//  PasswordAlert.swift
//  ZNZXSuperMarket
//
//  Created by 四川中农 on 2018/9/7.
//  Copyright © 2018年 四川中农. All rights reserved.
//

import UIKit

class PasswordAlert: UIView {
    
    var backPassWord:BackStringValue!
    var close:TouchBlock!

    @IBOutlet weak var field: UITextField!
    /*
    // Only override draw() if you perform custom drawing.
    // An empty implementation adversely affects performance during animation.
    override func draw(_ rect: CGRect) {
        // Drawing code
    }
    */
    
    @IBAction func closeMethod(_ sender: UIButton) {
        if self.close != nil{
            self.close()
        }
    }
    
    @IBAction func confirmPayMethdo(_ sender: UIButton) {
        guard self.field.text != "" else {
            PKhud.showText(text: "请输入密码~")
            return
        }
        if self.backPassWord != nil{
            self.backPassWord(self.field.text!)
        }
    }
    
}
